<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
	<title>Инфомат</title>
	<meta http-equiv="Content-Type" content="text/html; charset=windows-1251">
    <meta name="description" content="">
	<meta name="keywords" content="">
	<meta name="copyright" content="">
	<meta name="author" content="">
	<link rel="stylesheet" href="/templates/main/style.css" type="text/css">
</head>

<body onselected="return false;">

<!-- КРАСИВАЯ ОБЕРТКА ДЛЯ ВЫВОДА ОШИБОК ЮЗВЕРЯМ -->
    <TABLE
            id="forma"
            border="0"
            onmousedown="this.style.display = 'none';"
            valign="middle"
            width="100%"
            height="100%"
            class="error_visual_container"
            style="display: none;">
            <tr>
                <td align="center" valign="bottom" id="messagecontainer" style="vertical-align: bottom; color: white; font-size: 2em; color: white;">
                    &nbsp;
                </td>
            </tr>
            <tr>
                <td align="center" valign="top" style="vertical-align: top; color: white; font-size: 2em; color: white;">
                    <font style="font-size: 0.8em;">Прикоснитесь к экрану, чтобы вернуться к выбору.</font>
                </td>
            </tr>
    </TABLE>
    <SCRIPT type="text/javascript">
        function xalert(message)
        {
            var Layer = document.getElementById('forma');
            Layer.style.display = '';
            var Layer = document.getElementById('messagecontainer');
            messagecontainer.innerHTML = message; 
        }
    </SCRIPT>

    <TABLE
            id="forma2"
            border="0"
            onmousedown="this.style.display = 'none';"
            valign="middle"
            width="100%"
            height="100%"
            class="error_visual_container"
            style="display: none;">
            <tr>
                <td align="center" valign="bottom" id="messagecontainer2" style="vertical-align: bottom; color: white; font-size: 2em; color: white;">
                    &nbsp;
                </td>
            </tr>
            <tr>
                <td align="center" valign="top" style="vertical-align: top; color: white; font-size: 2em; color: white;">
                    <font style="font-size: 0.8em;">Идет проверка данных.</font>
                </td>
            </tr>
    </TABLE>
    <script type="text/javascript">
        function xalert2(message)
        {
            var Layer = document.getElementById('forma2');
            Layer.style.display = '';
            var Layer = document.getElementById('messagecontainer2');
            messagecontainer2.innerHTML = message; 
        }
    </script>
<!-- КОНЕЦ КРАСИВОЙ ОБЕРТКИ -->

<table width="100%" height="100%" cellspacing="0" cellpadding="0" border="0" style="table-layout: fixed;">
    <tr height="18">
      <td class="cor1">&nbsp;</td>
      <td class="cor2">&nbsp;</td>
      <td class="cor3">&nbsp;</td>
      <td class="cor4">&nbsp;</td>
      <td class="cor5">&nbsp;</td>
    </tr>
    <tr>
      <td class="cor6" rowspan="2">&nbsp;</td>
      <td class="cor9" colspan="3" rowspan="5" style="padding: 20px; ">

	        <TABLE border="0" width="100%" height="100%" cellspacing="0" cellpadding="0" style="min-height: 100%; height:auto !important; height: 100% !important;">
	        <TR>
                <TD>
		            <TABLE border="0" cellspacing="0" cellpadding="0" width="100%" height="100%">
		            <TR>
                        <TD height="100">
                            <TABLE width="100%">
                                <TR>
			                        <TD>
                                        <div class="logo3"></div>
                                    </TD>
                                    <TD width="20%" height="110" style="vertical-align: middle; text-align: right;">
                                        <div class="logo2"></div>
                                    </TD>
                                </TR>
                            </TABLE>
                        </TD>
                    </TR>
                    <TR>
                        <TD>
                            {{$BODY}}
                        </TD>
                    </TR>
                    </TABLE>
                </TD>
            </TR>
            <TR>
                <TD align="right" height="126" style="padding-right: 0em; padding-left: 0em;">
                    <TABLE width="100%" cellspacing="0" cellpadding="0" border="0">
                    <TR>
                        <TD align="left" width="*"><?php addMainButton(Array(2,3,4), 0, "location.href='".$mainpage."';");?></TD>
                        <TD align="right" width="286"><?php addMainButton(Array(3), 1, $returnbutton_action);?></TD>
                        <TD align="right" width="286"><?php addMainButton(Array(1,2,3), 2, $nextbutton_action);?></TD>
                    </TR>
                    </TABLE>
                </TD>
            </TR>
            </TABLE>

      </td>
      <td class="cor7"></td>
    </tr>
    <tr>
      <td class="cor8"></td>
    </tr>
    <tr>
      <td class="cor11"></td>
      <td class="cor8a"></td>
    </tr>
    <tr>
      <td class="cor11a"></td>
      <td class="cor13" rowspan="2"></td>
    </tr>
    <tr>
      <td class="cor12"></td>
    </tr>
    <tr height="81">
      <td class="cor14"></td>
      <td class="cor15">Разработано ЗАО «Система Витакор<br>E-mail: main@doktor16.ru</td>
      <td class="cor18"></td>
      <td class="cor16"></td>
      <td class="cor17"></td>
    </tr>
</TABLE>

<script type="text/javascript">
    function goNext()
    {
        document.location.href = '<?php echo $nextpage;?>';
    }

    function goBack()
    {
        document.location.href = '<?php echo $prevpage;?>';
    }

    function m_main_down(obj,index)
    {
        x = -index*286;
        y = -96;
        obj.style.backgroundPosition = x+" "+y;
    }

    function m_main_up(obj,index)
    {
        x = -index*286;
        y = 0;
        obj.style.backgroundPosition = x+" "+y;
    }
</script>

<?php
    if(isset($_GET['errortext']))
    {
        ?>
        <script type="text/javascript">
        xalert("<?php echo $_GET['errortext'];?>");
        </script>
        <?php
    }
?>

</body>
</html>